package com.zhiwang.planet.mvvm.model.entity

import androidx.room.*

@Entity(tableName = "table_downLoaded_apk")
class DownLoadedApk(
        var appName: String,
        @PrimaryKey
        var packageName: String,
        var downloadUrl: String,
        //本地保存路径
        var packagePath: String)


@Dao
interface DownLoadApkDao {

    @Query("SELECT * FROM table_downLoaded_apk WHERE packageName =:key")
    fun getDownLoadApk(key: String):DownLoadedApk

    @Insert
    fun addDownLoadApk(downloadApk: DownLoadedApk)
}